@extends('layouts.app')

@section('content')

    <div class="vertical-push-50"></div>

    <div class="auth-page-view">
        <div class="container">
            <div class="row">
                <div class="col-xs-12 col-md-4 col-md-offset-4">
                    <form class="login-form" role="form" method="POST" action="/admin/login">
                        {!! csrf_field() !!}

                        <div class="form-header page-header text-center">
                            <h3>后台管理系统</h3>
                        </div>

                        <div class="form-group {{ $errors->has('email') ? 'has-error' : '' }}">

                            <input type="email" class="form-control" name="email" value="{{ old('email') }}" placeholder="邮箱" autofocus>

                            @if ($errors->has('email'))
                                <span class="help-block">
                                <strong>{{ $errors->first('email') }}</strong>
                            </span>
                            @endif
                        </div>

                        <div class="form-group {{ $errors->has('password') ? 'has-error' : '' }}">

                            <input type="password" class="form-control" name="password" placeholder="密码">

                            @if ($errors->has('password'))
                                <span class="help-block">
                                <strong>{{ $errors->first('password') }}</strong>
                            </span>
                            @endif
                        </div>

                        {{-- remember user by default --}}
                        <div class="form-group hidden">
                            <div class="checkbox">
                                <label>
                                    <input type="checkbox" name="remember" checked>记住我
                                </label>
                            </div>
                        </div>

                        <div class="form-group">
                            <button type="submit" class="btn btn-primary btn-block">登录</button>
                        </div>

                        <p>
                            <a href="{{ url('/admin/password/reset') }}">忘记密码?</a>
                        </p>

                    </form>
                </div>
            </div>
        </div>
    </div>
@endsection
